﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Print.Master" AutoEventWireup="true" CodeBehind="News.aspx.cs" Inherits="Print.News" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CpHead" runat="server">
<script type="text/javascript">
    $(function () {
        //导航
        var thisnav = $("#nav<%=mid %>");
        thisnav.addClass("navhover");

        var navli = $("#navigation-list li");
        navli.mousemove(function () { $(this).addClass("navhover"); });
        navli.mouseout(function () {
            $(this).removeClass("navhover"); if (!$(this).siblings().hasClass('navhover')) { thisnav.addClass("navhover"); }
        });

        var menuli = $(".submenu-main li");
        menuli.mousemove(function () { $(this).addClass("submenu-hover-bg"); });
        menuli.mouseout(function () { $(this).removeClass("submenu-hover-bg"); });
        newList(<%=ps %>, 0);
    });
    function newList(s, p) {
        var now = new Date();
        var val = "";
        $.getJSON("DoAjax.ashx?act=news&size=" + s + "&page=" + p + "&t=" + now.getTime(), function(data) {
            $.each(data.list, function(i,item){
              val += '<li><span class="right">点击量：'+item.value+'</span><a href="<%=config.P_WebPath %>/news/'+item.id+'.aspx" target="_blank">'+item.title+'</a></li>';
            });
            $("#news-list").html(val);
            $("ul", ".pages").html(data.page[0].cont);
        }).error(function() { alert("error"); })
        .complete(function () { 
            $("#news-list li:even").css('background', '#E1E1E1');
            $("#news-list li:odd").css('background', '#F3F3F3'); 
            $(".pages ul li").mousemove(function () { $(this).addClass("hov"); });
            $(".pages ul li").mouseout(function () { $(this).removeClass("hov");});
        });
    }

    function goto(uri) {
        location.href = uri;
    }
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CpSlider" runat="server">
<asp:Repeater ID="AdRpt" runat="server">
<HeaderTemplate><ul></HeaderTemplate>
<ItemTemplate><li><a href="<%# Eval("AUrl") %>"><img src="<%=config.P_WebPath %><%# Eval("APic") %>" width="918" height="250" alt="<%# Eval("AName") %>" /></a></li></ItemTemplate>
<FooterTemplate></ul></FooterTemplate>
</asp:Repeater>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="CpLeft" runat="server">
<div class="leftbar-cpal">
	<div class="submenu-header"><img src="<%=config.P_WebPath%>/images/submenu-title-about.gif" width="230" height="82" alt="印刷服务分类" /></div>
	<div class="submenu-main">
		<ul>
			<asp:Repeater ID="BaseRpt" runat="server">
				<ItemTemplate>
					<li id="t<%# Eval("Id") %>" onclick="goto('<%# Eval("MUrl") %>');"><%# Eval("MTitle") %></li>
				</ItemTemplate>
			</asp:Repeater>
		</ul>
	</div>
	<div class="submenu-footer"><img src="<%=config.P_WebPath%>/images/submenu-footer.gif" width="230" height="38" alt="submenu-footer" /></div>
</div>
<div class="leftbar-contact-info">
	<div class="cpl-contact"><img src="<%=config.P_WebPath%>/images/child-pages-leftbar-contact-icon.gif" alt="" /></div>
	<div class="online-service"><img alt="" src="<%=config.P_WebPath%>/images/child-pages-leftbar-online-server.gif" usemap="#Map3"/>
		<map name="Map3" id="Map3">
			<area shape="rect" coords="107,9,167,65" alt="菜谱业务咨询 "href="http://wpa.qq.com/msgrd?V=3&Uin=775473306&Site=QQ/&Menu=yes" target="_blank" />
			<area shape="rect" coords="178,9,234,65" alt="加盟合作咨询 "href="http://wpa.qq.com/msgrd?V=3&Uin=1735831376&Site=QQ/&Menu=yes" target="_blank" />
		</map>
	</div>
	<div class="cpl-address" style="width:230px;overflow:hidden"><div class="company-title"><span>营业部信息：</span></div>
		<div class="company-info">
			<p><span>地址：</span><%=config.P_Add %></p>
			<p><span>电话：</span>0756-6222333</p>
            <p><span>传真：</span><%=config.P_Fax %></p>
			<p><span>手机：</span><%=config.P_Tel %> 梁生</p>
		</div>
	</div>
</div>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="CpRight" runat="server">
<div class="mainbox-chef-data-title" id="bTit" runat="server">
</div>
<div class="content">
    <div id="detials" class="details" runat="server">
        <ul id="news-list" class="news-list">
            <asp:Repeater ID="NewsRpt" runat="server">
            <ItemTemplate>
            <li>
		        <span class="right">点击量：<%# Eval("NHit") %></span>
		        <a href="<%#Eval("Id") %>" target="_blank"><%# Eval("NTitle") %></a>
	        </li>
            </ItemTemplate>
            </asp:Repeater>
        </ul>
        <div class="pages">
	        <ul>
            </ul>
        </div>

    </div>
</div>
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="CpLink" runat="server">
</asp:Content>
